package com.hlingsoft.kkh.entity;

import com.hlingsoft.kkh.constant.JobConstant;
import com.hlingsoft.kkh.constant.MerchantConst;

import java.util.Date;

/**
 * Created by Administrator on 2015/1/14.
 */
public class Job {
    private long id;
    private long merchantId;
    private String merchantName;
    private String name;
    private String imageUrl;
    private String jobAddress;
    private String jobTime;
    private MerchantConst.IsAttestation isAttestation;

    public String getJobTime() {
        return jobTime;
    }

    public void setJobTime(String jobTime) {
        this.jobTime = jobTime;
    }

    public String getJobAddress() {
        return jobAddress;
    }

    public void setJobAddress(String jobAddress) {
        this.jobAddress = jobAddress;
    }

    private Date createTime;
    private long recruitNum;
    private long candidateNum;
    private JobConstant.SalaryType salaryType;
    private double amount;
    private Date updateTime;
    private Date startTime;
    private Date endTime;
    private JobConstant.Status status;
    private int jobType;
    private JobConstant.PayCycle payCycle;
    private String payCycleString;
    private String description;


    public void setPayCycleString(String payCycleString) {
        this.payCycleString = payCycleString;
    }

    public MerchantConst.IsAttestation getIsAttestation() {
        return isAttestation;
    }

    public void setIsAttestation(MerchantConst.IsAttestation isAttestation) {
        this.isAttestation = isAttestation;
    }

    public String getMerchantName() {
        return merchantName;
    }

    public void setMerchantName(String merchantName) {
        this.merchantName = merchantName;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public long getMerchantId() {
        return merchantId;
    }

    public void setMerchantId(long merchantId) {
        this.merchantId = merchantId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getImageUrl() {
        return imageUrl;
    }

    public void setImageUrl(String imageUrl) {
        this.imageUrl = imageUrl;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public long getRecruitNum() {
        return recruitNum;
    }

    public void setRecruitNum(long recruitNum) {
        this.recruitNum = recruitNum;
    }

    public long getCandidateNum() {
        return candidateNum;
    }

    public void setCandidateNum(long candidateNum) {
        this.candidateNum = candidateNum;
    }

    public JobConstant.SalaryType getSalaryType() {
        return salaryType;
    }

    public void setSalaryType(JobConstant.SalaryType salaryType) {
        this.salaryType = salaryType;
    }

    public double getAmount() {
        return amount;
    }

    public void setAmount(double amount) {
        this.amount = amount;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public JobConstant.Status getStatus() {
        return status;
    }

    public void setStatus(JobConstant.Status status) {
        this.status = status;
    }

    public int getJobType() {

        return jobType;
    }

    public void setJobType(int jobType) {
        this.jobType = jobType;
    }

    public JobConstant.PayCycle getPayCycle() {
        return payCycle;
    }

    public void setPayCycle(JobConstant.PayCycle payCycle) {
        this.payCycle = payCycle;
    }

    public String getPayCycleString() {
        if (this.payCycle.equals(JobConstant.PayCycle.day)) {
            return "元/天";
        } else if (this.payCycle.equals(JobConstant.PayCycle.hour)) {
            return "元/时";
        } else if (this.payCycle.equals(JobConstant.PayCycle.month)) {
            return "元/月";
        } else if (this.payCycle.equals(JobConstant.PayCycle.week)) {
            return "元/周";
        }
        return "";
    }
}
